gpg: Fix ot_gpgme_error_to_gio_error()
authorMatthew Barnes <mbarnes@redhat.com>
Thu, 7 May 2015 20:02:39 +0000 (16:02 -0400)
committerMatthew Barnes <mbarnes@redhat.com>
Thu, 7 May 2015 20:02:39 +0000 (16:02 -0400)
Need to extract the error code from a gpgme_error_t, can't just compare
it directly.

src/libotutil/ot-gpg-utils.c

index 88b436f24b80ef1c04cab79e16b30627a3c7d2a6..d603b09b227a832be0a61d43f724c94413d509aa 100644 (file)
@@ -34,7 +34,7 @@ ot_gpgme_error_to_gio_error (gpgme_error_t   gpg_error,
 
   /* XXX This list is incomplete.  Add cases as needed. */
 
-  switch (gpg_error)
+  switch (gpgme_err_code (gpg_error))
     {
       /* special case - shouldn't be here */
       case GPG_ERR_NO_ERROR: